home *** CD-ROM | disk | FTP | other *** search
/ Nautilus 1992 July / Nautilus-3-8 / Nautilus-3-8.bin / Tools & Utilities / Techy Stuff / Frontier Scripts / Folder Monitor < prev    next >
Encoding:
Text File  |  1992-06-12  |  1.8 KB  |  39 lines

  1. Enclosure: FileShare Monitor.PKG
  2.  
  3.     Enclosed is a script for handling an "agent" that watches a folder.  It is
  4. similar to the "Trashland" agent that is in 1.0b3.  I have extended it to work
  5. over FileShare, however it can work just about anywhere.
  6.  
  7.     Things of note:
  8.  
  9.     1. FileShare creates an invisble folder inside of of shared folders.  It's
  10. called "Network Trash Folder".  This agent ignores this folder because it
  11. ignores all folders in general.  However, it would be nice if there were a
  12. "file.isHidden" call to see if the file/folder is hidden, and if it is then oyu
  13. could ignore it.
  14.  
  15.     2.  This agent waits until all file copying is finished before beginning
  16. actions by checking the "file.isbusy" verb for each file.  It doesn't have to
  17. be this way, you could change it to start of files that are no longer busy.
  18. I'm not sure how you might treat the LastModDate variable though.
  19.  
  20.     3.  This agent sends an AppleEvent to Hypercard as it's action.  You can
  21. replace this with any action you want.
  22.  
  23.     I tried to design this agent with FileShare in mind.  I had this idea of
  24. setting up a networked machine with FileShared folders and a variety of
  25. AppleEvent aware applications and Frontier running on it.  Users could access
  26. services of this machine by dropping files into the FileShared folders.  The
  27. Fronteir agent would see new files and activate scripts to do actions, like
  28. translation, text massaging, etc.  It would control the file routing so that
  29. the finished product might end up in another FileShared folder called "Finished
  30. Requests".  The user might have their own copy of Frontier watching that folder
  31. so it could go "bing" when a file appeared.  The user could then go and get the
  32. the file.  "Desktop Services" without tying up your own machine.  I don't know
  33. if this is all possible today, but it can't be too far away.
  34.  
  35. Enjoy,
  36.  
  37. Mark
  38. Author: D1180
  39.